package com.ding.easycontroller.dao.impl;

import com.ding.easycontroller.dao.WebSocketDao;
import com.ding.easycontroller.file.WebSocketFile;
import com.ding.easycontroller.work.WebSocket;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * 脚本持有者
 */

@Repository
public class WebSocketDaoImpl implements WebSocketDao {


    @Autowired
    private WebSocketFile websocketFile;

    @Override
    public List<WebSocket> listAll() {
        return websocketFile.listAll();
    }

    @Override
    public void removeById(String id) {
        websocketFile.removeById(id);
    }

    @Override
    public void update(WebSocket websocket) {
        websocketFile.update(websocket);
    }

    @Override
    public void add(WebSocket websocket) {
        websocketFile.add(websocket);
    }


}
